/*
 *  NedAllocPolicy.cpp
 *  RTDemo
 *
 *  Created by steveca  on 13/05/09.
 *  Copyright 2009 __MyCompanyName__. All rights reserved.
 *
 */

#include "NedAllocPolicy.h"
#include "nedmalloc.h"

namespace Sdlfw {
    
	void *NedAllocImpl :: allocBytes(size_t size)
	{
		void* ptr = nedalloc::nedmalloc(size);
		// std::cout<<"Allocating Mem Using NedAlloc" << std::endl;
		return ptr; 
	}
	
    void *NedAllocImpl :: allocBytes(size_t size,
                                     const char *file, int line, const char *func)
    {
        void* ptr = nedalloc::nedmalloc(size);
		// std::cout<<"Allocating Mem Using NedAlloc" << std::endl;
		return ptr;
    }
    
    void NedAllocImpl :: deallocBytes(void *ptr)
    {
        if (!ptr)
			return;
        
		nedalloc::nedfree(ptr);
		// std::cout<<"Deallocating Mem Using NedAlloc" << std::endl;
    }
    
    void *NedAllocImpl :: allocBytesAligned(size_t align, size_t size, 
                                            const char *file, int line, const char *func)
    {
        
    }
    
    void NedAllocImpl :: deallocBytesAligned(size_t align, void *ptr)
    {
        
    }
    
	
    
}
